package javabase.schoolwork.day5_24;

/**
 * @author fance
 * @date 2018/5/24 19:57
 */
public class Operation {
    private long num;
    private String name;
    private double salary;
    private double bonus;

    public Operation(long num, String name, double salary, double bonus) {
        this.num = num;
        this.name = name;
        this.salary = salary;
        this.bonus = bonus;
    }

    public Operation() {
    }

    public long getNum() {
        return num;
    }

    public void setNum(long num) {
        this.num = num;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public double getSalary() {
        return salary;
    }

    public void setSalary(double salary) {
        this.salary = salary;
    }

    public double getBonus() {
        return bonus;
    }

    public void setBonus(double bonus) {
        this.bonus = bonus;
    }

    @Override
    public String toString() {
        return "Operation{" +
                "num=" + num +
                ", name='" + name + '\'' +
                ", salary=" + salary +
                ", bonus=" + bonus +
                '}';
    }


    public double getYearSalary() {
        return 12 * salary + bonus;
    }
    public double getMonthSalary() {
        return salary;
    }
    public double getDaySalary() {
        return salary / 30;
    }


}
